import 'package:flutter/material.dart';
import '../theme/theme.dart';

/// 页脚组件
class UndersideFooter extends StatelessWidget {
  /// 版权信息
  final String? copyright;

  const UndersideFooter({
    super.key,
    this.copyright,
  });

  @override
  Widget build(BuildContext context) {
    final theme = HTheme.of(context);
    
    return Container(
      height: 30,
      padding: const EdgeInsets.symmetric(horizontal: 16),
      decoration: BoxDecoration(
        color: Colors.white,
        border: Border(
          top: BorderSide(color: theme.colors.divider),
        ),
      ),
      child: Row(
        mainAxisAlignment: MainAxisAlignment.end,
        children: [
          Text(
            copyright ?? '© 2025 Flutter Miaoyi UI框架',
            style: TextStyle(
              color: theme.colors.textSecondary,
              fontSize: 12,
            ),
          ),
        ],
      ),
    );
  }
} 